home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format 16 / af016.adf / AMOS readme < prev    next >
Text File  |  1978-01-17  |  25KB  |  604 lines

  1.  
  2.                       AMOS The Creator Version 1.2 updater
  3.                         
  4.                                By Fran‡ois Lionet
  5.  
  6.                             (c) 1990 Mandarin / Jawx
  7.  
  8.  
  9.                            Important copyright notes
  10.                           ---------------------------                     
  11.  
  12.      The AMOS Basic 1.2 Updater is public domain. You can (and you
  13.      are encouraged to) copy and distribute it freely. It does not mean
  14.      AMOS Basic itself is public domain. Copyright remains on the
  15.      interpreter, and on the updated version.
  16.          You need AMOS Basic V1.1 to make the adaptation.
  17.  
  18.  
  19.                                    RAMOS V1.2
  20.                                   ------------
  21.  
  22.      This updater does not contain an update for the RAMOS run time system.
  23.      Due to the limited disc space we are unable to bring you this but it
  24.      can be obtained directly from PD libraries and Sandra Sharkey of
  25.      course! Her new address is:
  26.  
  27.                               The AMOS PD Library
  28.                                   25 Park Road
  29.                                      Wigan
  30.                                     WN6 7AA
  31.  
  32.                    Telephone (0942) 495261 for latest PD news
  33.  
  34.                                 How to proceede
  35.                                ------------------
  36.  
  37.      Updating your AMOS Basic will only take you a little time but you must
  38.      keep to these instructions. Hard drive users should proceed on floppy
  39.      disc first, and then copy across the new AMOS files to their hard
  40.      drive.
  41.  
  42.          1 Format a blank disc.
  43.  
  44.          2 Set the protection tab of your original AMOS Programs disc to
  45.            avoid accidental erasure of your master.
  46.  
  47.          3 Using Workbench's DUPLICATE option (or a commercial copier such
  48.            as XCOPY,) create a back-up of the AMOS Programs disc onto the
  49.            newly formatted disc.
  50.  
  51.          4 Boot up the disc with the AMOS Update on it (Amiga Format                       Šdisk 16 November 1990)
  52.  
  53.          5 Double click on the AMOS Update disc icon and then on the
  54.            resulting AMOS Update program icon.
  55.  
  56.          6 The updater will load and a small window will appear. From this
  57.            point onwards, simply follow and answer the on screen prompts.
  58.  
  59.          7 When the updater has finished, place the new version in Df0 and
  60.            press Control+Amiga+Amiga keys to boot into AMOS V1.2.
  61.  
  62.          * Please note that the updater will delete many files from the
  63.            backed-up AMOS disc - so please don't use your original master!
  64.  
  65.          * If everything was right, you will now have a working copy of
  66.            AMOS version 1.2 - make a backup as a precaution. And never go
  67.            back to V1.1.
  68.  
  69.                                 Hard disc users
  70.                                -----------------
  71.  
  72.      Once you have Version 1.2 on a floppy disc you simply have to copy
  73.      across the following files onto your hard disc:
  74.  
  75.          Folder: AMOS_System
  76.  
  77.            AMOS2_1.Env       - AMOS environment file. Replaces "AMOS.Env"
  78.            Compact           - AMOS (bug free compacter) Version 1.2.
  79.                                Replaces "Compact" file size should be 1816
  80.                                bytes long
  81.  
  82.          Folder: AMOS root directory (where you always load AMOS from)
  83.  
  84.            AMOS2.1           - AMOS program file. Replaces "AMOS"
  85.            AMOS2.1.Info      - AMOS workbench icon. Replaces "AMOS.Info"
  86.  
  87.  
  88.                  What's new in version 1.2 - by Fran‡ois Lionet
  89.                 ------------------------------------------------
  90.  
  91.      Although we have tested AMOS during many months before releasing it,
  92.      we have missed a few bugs. Mandarin and I are also VERY concerned
  93.      about the user's request, and we read ALL the letters you send us.
  94.  
  95.          AMOS version 1.2 is the first result of your bug reports and
  96.      suggestions. We all hope you find this "public domain" way of
  97.      releasing new versions convenient (mostly for your purse!).
  98.  
  99.          Now, let's go for the list of new things! First, the bugs:
  100.  
  101.          1 Nasty bugs!
  102.  
  103.            * HELP accessory crashed on the A500
  104.            * Accessory calling also invited the guru with certain
  105.              screen configurations
  106.            * GARBAGE collection caused a crash if it occurred in the
  107.              middle of a string expression, and if the collection could not
  108.              get enough space to finish the evaluation. (baaaad bug, I tell
  109.              ya man!)
  110.            * GENLOCKed Amiga could not get a still picture
  111.            * Global variables in procedure calls (I could not imagine
  112.              people would actually DO that!)
  113.            * CLOSE WORKBENCH used to crash if a window was opened on WB
  114.              screen. Now this instruction is really closer to Commodore
  115.              specifications, so the AMOS1_2.AMOS program had to change the
  116.              Startup-Sequence of the language disc
  117.  
  118.              Note that CLOSE WORKBENCH will NOT work now if you have one
  119.              CLI window opened. If you want to start AMOS and actually
  120.              close the workbench, you must use the following CLI
  121.              instructions:
  122.  
  123.                RUN >NIL: AMOS
  124.                ENDCLI
  125.  
  126.          2 Other bugs.
  127.  
  128.          * LDIR now works properly
  129.          * Y HARD now returns the right value
  130.          * SCIN does not report hidden screens
  131.          * VAL works with negative floating numbers!
  132.          * PLOT works with large float expressions. In fact, the problem
  133.            was in the "double float evaluation" routine. All instruction
  134.            that required TWO parameters were affected.
  135.          * INT is corrected
  136.          * SQR(-2) and LOG(-1..) now returns an illegal function call error
  137.          * Def Fn with float numbers does not report a type mismatch error
  138.            any more
  139.          * I SPRITE and I BOB are now tokenised
  140.          * AMAL PLay instruction now works fine
  141.          * AMPLAY too
  142.          * AMAL OR is now understood by AMAL
  143.          * ERRN reports the REAL error number (it used to add TWO to it!)
  144.          * CONTROL+C now cuts the block under editor
  145.          * CONTROL+S stores the block
  146.          * You can now go from one label to another with ALT arrows
  147.          * GET FONTS information used to be corrupted by a garbage
  148.            collection - now this is fixed
  149.          * MENU TO X,Y is now in the right order
  150.          * DOUBLE BUFFERED , DUAL PLAYFIELD screens were not displayed,
  151.            making it impossible to use bobs on dual playfield
  152.          * UNPACK works fine with portions of screens
  153.          * SET TAB now works in a program
  154.  
  155.          3 Manual bugs.
  156.  
  157.          Yes! A few mistakes in the manual made us think there were
  158.          more bugs in AMOS. Here are the faulty instructions in the manual.
  159.  
  160.          * PRG FIRST needs a filter, like DIR FIRST: =PRG FIRST$("*.*")
  161.          * COLOUR BACK $RGB is an instruction that sets the background
  162.            colour of the screen, ie the colour OUTSIDE of all screens.
  163.          * AMREG wants the CHANNEL number FIRST, and then the register
  164.            number, and not the contrary as stated in the manual.
  165.  
  166.          Well, sorry for the bugs. Each time a user found a new one, I
  167.      felt bad! Sorry for that, but you must realise that AMOS source code
  168.      is over 1 Megabyte long! The most difficult thing in such big
  169.      programs, is that when you change something at one corner, it may be
  170.      creating a bug in a very far routine that you had almost forgotten!
  171.  
  172.  
  173.                             New Features in AMOS 1.2
  174.                            --------------------------
  175.  
  176.       1  The new improved File Selector
  177.  
  178.            Certainly a subject on which we had the most remarks and ideas!
  179.            What's new then:
  180.  
  181.            * You can now type stuff, and click when the directory is
  182.              loading.
  183.                As a consequence, the directory is not sorted any more, but
  184.              I have provided a SORT button. You can keep clicking on it if
  185.              you cannot stand seeing the directory in a mess!
  186.            * The up and down arrows are grouped in the top of the file
  187.              list.
  188.            * The PARENT button is just over the arrows, giving fast access
  189.              to all three buttons.
  190.            * No more device list on the right of the files! To have it,
  191.              just do as in the ARP file  selector: click on the right mouse
  192.              button. The device  REAL  names  (including  ASSIGNED devices)
  193.              list will be displayed. Just click  on  the name to change the
  194.              disc.
  195.            * The requester is not disabled as it was before. If you ask for
  196.              an non-existent disc, it will ask to insert it.
  197.            * That's it. Some major changes that will (I hope) satisfy your
  198.              needs. Note that the program selector has changed too. No
  199.              kidding, how did you guess I was using the same routines?
  200.            * The slider bar's display is now cleaner
  201.            * Sequential files are now 3 times faster. I was really ashamed
  202.              to be slower than Amiga Basic!
  203.            * =DIR$ now returns the disc name, and not only the device
  204.              reference.
  205.            * AMOS is now even more multi-tasking. The editor and the direct
  206.              mode do not do "busy" loops any more. You can normally run
  207.              other tasks on the background. Of course, when a program is
  208.              running, AMOS takes as much processor  time  as it can to have
  209.              the best speed. See the  new  MULTI WAIT instruction below for
  210.              more details.
  211.  
  212.  
  213.       2 New instructions
  214.  
  215.          Yes, as a bonus, for no extra cost!
  216.  
  217.          * =DEV FIRST$("filter")
  218.          * =DEV NEXT$
  219.  
  220.            Like DIR FIRST$ and DIR NEXT$, but for the device list.
  221.            Note that you should remove the spaces with -" " to get the
  222.            right name.
  223.  
  224.          * MULTI WAIT
  225.  
  226.            To make REAL multi-task programs, you must not grab all the
  227.            processor time (as I used to do in V1.1), and leave some power
  228.            to the other tasks. MULTI WAIT does a MULTI-TASK wait vbl. You
  229.            should use it in your program's main loop, when you wait for
  230.            example for a menu item to be selected.
  231.  
  232.            Note that you should not use this instruction to make accurate
  233.            screen synchronisation. As it is designed to multi-task, this
  234.            instruction is NOT ACCURATE AT ALL! It may skip many VBLs,
  235.            depending on the number of running task at the moment.
  236.  
  237.            If you missed it in the manual, multitasking can be activated by
  238.            pressing Amiga+A to flick between AMOS and the CLI or Workbench
  239.            environments. This allows systems with at least 1 meg to run
  240.            AMOS and programs like DPAINT III at the same time!
  241.  
  242.          * PRIORITY REVERSE ON
  243.          * PRIORITY REVERSE OFF
  244.  
  245.            When I had finished AMOS, someone told me that I had made a
  246.            really stupid mistake: the bob priority display order in AMOS
  247.            was REVERSED to that in STOS. Silly me! It made it more
  248.            difficult to port programs from STOS to AMOS - but not
  249.            impossible! I had to correct this!
  250.  
  251.            PRIORITY REVERSE ON, as it says, reverses the entire bob's
  252.            priority table. It means that bob number 1 will be first, in
  253.            front of all other bobs, 2 will come in second etc... This
  254.            priority list is compatible with STOS.
  255.  
  256.            This instruction has another really nice feature when you use it
  257.            with PRIORITY ON. The bobs are not sorted from TOP to BOTTOM any
  258.            more, but from BOTTOM to TOP! The highest bob on the screen will
  259.            be displayed in front of the others - how to turn a mistake into
  260.            a nice new feature!
  261.  
  262.          * Automatic sprite flipping - a very special feature - really
  263.            crucial!
  264.  
  265.            In a great number of games, the main character needs to animate
  266.            left to right, and up and down. Up to now, you were obliged to
  267.            keep in the sprite bank reversed copies of small animation
  268.            sequences for the main character. As  the  main  character
  269.            usually has the best animation, you lose an enormous amount of
  270.            space!
  271.  
  272.            For the game RanXerox (out now!), which I wrote a long time ago,
  273.            I produced a nice flipping routine which allowed me to keep just
  274.            one copy of the main character in the bank. I have grabbed and
  275.            enhanced this routines for AMOS, and it is now a part of Version
  276.            1.2.
  277.  
  278.            I had to be clever (who said I could not?) to find a way of
  279.            including this feature and keep compatibility with older
  280.            programs.
  281.  
  282.            How does it work? Let's imagine your character is walking to the
  283.            left and then back to the right. You would only have in your
  284.            bank the image of him walking to the right. To display this
  285.            right image, you simply refer to the image number in the bank as
  286.            usual.
  287.  
  288.            To display the image reversed in the X axis (left walking
  289.            image), you set bit number 15 of the image number to 1. Don't
  290.            panic, you can simply do it with:
  291.  
  292.              $8000+Image number
  293.  
  294.            So, BOB 1,160,100,1 will display your character walking right,
  295.            and BOB 1,160,100,$8000+1 will display it walking left. The same
  296.            principle is used for vertical reversing, for this, bit number
  297.            14 is used. Add $4000 to the image number. To have a vertical
  298.            and horizontal reversing, use $C000.
  299.  
  300.            The symmetry is a full symmetry: I also reverse the HOT SPOT of
  301.            the bob. For example, if we had put the hot spot in X under the
  302.            feet of our character, the reversed version would also have it
  303.            under its foot. So be careful if you set the hot spot on the top
  304.            left corner on a bob, the reversed image will be displayed at
  305.            the top left!
  306.  
  307.            You might say that $8000 and $C000 is a bit weird to use. I
  308.            have provided special functions to give a better AMOS interface:
  309.  
  310.              * =HREV(image), add $8000 to the image
  311.              * =VREV(image), add $4000
  312.              * =REV(image), add $C000
  313.  
  314.              Use them in place of the hex values:
  315.  
  316.                BOB 1,160,100,10
  317.                BOB 1,160,100,HREV(10)
  318.                BOB 1,160,100,VREV(10)
  319.                BOB 1,160,100,REV(10)
  320.  
  321.            To allow easy use of the bob reverser in AMAL, I have
  322.            implemented HEXADECIMAL evaluation. So you can use hex notation
  323.            to refer easily to reversed bobs. If hex frightens you, just add
  324.            $8000, $4000 or $C000 before all references in your AMAL
  325.            strings.
  326.  
  327.            Example:
  328.  
  329.              Old AMAL string:
  330.  
  331.                "Anim 0,(1,2)(2,2)(3,2)(4,2)"
  332.  
  333.              New reversed string:
  334.  
  335.                "Anim 0,($8000+1,2)($8000+2)($8000+3)($8000+4)"
  336.              or...
  337.  
  338.                "Anim 0,($8001,2)($8002,2)($8003,2)($8004,2)"
  339.  
  340.            If you use a register to calculate the image number, do not try
  341.            to modify the calculation itself, but only when you assign the
  342.            register to the image.
  343.  
  344.              Old AMAL string:
  345.  
  346.                For R0=1 To 10; Let A=R0; Next R0
  347.  
  348.              New one:
  349.  
  350.                For R0=1 To 10; Let A=C000+R0; Next R0
  351.  
  352.      How does the flip routine work?
  353.  
  354.          It is really important for you to understand how it works
  355.          internally, so that you do not ask this system to do things it is
  356.          not designed to.
  357.  
  358.          I'll make myself a little bit clearer. This reversing system is
  359.          designed to increase memory before trying to be fast (although we
  360.  
  361.          would not mind if it was actually fast, would we?). I had to make
  362.          concessions to have it at the same time fast, easy and powerful.
  363.  
  364.          The routine actually works right in the middle of the bank, and
  365.          does not use any extra memory.
  366.  
  367.          The bobs are flipped during the UPDATE process, just before a bob
  368.          is redrawn on the screen: I look to see if the image needs to be
  369.          flipped in the bank. If it does, I do it and set a flag in the
  370.          bank. On the next UPDATE, if the bob image has not changed, I will
  371.          not need to flip it again, thus saving a lot of time.
  372.  
  373.          If you understand the above, you will also realise one BIG
  374.          limitation: It is not wise to use more than one flipped bob
  375.          pointing to the same image. Let's see the next example:
  376.  
  377.            Bob 1,160,100,1
  378.            Bob 2,160,150,$8001
  379.            Bob 3,20,20,$4001
  380.            Bob 4,20,100,$C001
  381.            Update
  382.  
  383.          During the UPDATE process, AMOS will first draw bob #1. No
  384.          problem, it is in the right position. Then bob #2 - AMOS needs to
  385.          reverse it in X. Bob #3 needs a Y and an X reversing (to put the
  386.          bob back to normal in X!). Then bob #4 needs an X flipping.
  387.  
  388.          On the next update, providing the bob's image has not changed,
  389.          to display bob #1, AMOS will have to flip it in X and Y, then bob
  390.          #2...
  391.  
  392.          As you can see, for each UPDATE, ie every 50th of second, if the
  393.          bobs move, they need to be reversed! This will work, but will take
  394.          a lot of processor time, and the animation will be disastrous.
  395.  
  396.          So the golden rule is: Use the reversed bobs for objects alone
  397.          on a screen (or be sure that normal and reversed images are not
  398.          displayed at the same time on the screen). If you want, you can
  399.          have two bobs like this - experiment!
  400.  
  401.          I told you before that this system was for use with BOBS. Yes, it
  402.          is totally automatic with bobs. But as it directly affects the
  403.          sprite bank, you can use it with sprites.
  404.  
  405.          When a hardware computed sprite is calculated, AMOS looks into the
  406.          sprite bank and gets the image from it. If the image is
  407.          reversed at that moment, the hardware sprite will display a
  408.          reversed image. You can therefore have reversed hardware sprites
  409.          using this method. But you cannot do for example:
  410.  
  411.            Sprite 1,200,200,$8001
  412.  
  413.          * Pasting flipped bobs
  414.  
  415.          PASTE BOB also accepts reversed images. A simple trick to
  416.          reverse an image in the bank without having to display a bob is to
  417.          PASTE the reversed image outside of the screen. Example:
  418.  
  419.            Paste Bob 500,500,$C000
  420.  
  421.          This will reverse image 4 in the bank, without any output (and
  422.          quite fast).
  423.  
  424.          * Collision Detection
  425.  
  426.          This is an important point, and you have to be very careful when
  427.          you detect collisions with reversed bobs!
  428.  
  429.          The collision detection uses the shapes in the bank at the very
  430.          moment it is called. Let's see an example that will never work:
  431.  
  432.            Bob 1,160,100,1
  433.            Do
  434.              Bob 2,XScreen(XMouse),YScreen(YMouse),$8001
  435.              Wait Vbl
  436.              Exit if Bob Col(1)
  437.            Loop
  438.  
  439.          Why doesn't it work? We have two reversed images of the same
  440.          definition in the bank. After the updating process, the image in
  441.          the bank is left reversed. So the Bob Col instruction will take
  442.          bob shape 1, the reversed image, and this will not work!
  443.  
  444.          So remember what uncle Fran‡ois tells you:
  445.          THOU SHALL NEVER USE COLLISION DETECTION WITH MORE THAN ONE
  446.          REVERSED IMAGE ON THE SCREEN!
  447.  
  448.          How is it coded into the sprite bank?
  449.  
  450.          I use two bits in the Hot spot X definition of each image in the
  451.          bank (at SPRITE BASE+6).
  452.  
  453.            Bit #15 for X: 0 if normal, 1 if reversed
  454.            Bit #14 for Y:    " "             " "
  455.  
  456.          Before RUN and SAVE, the bank is restored to its normal state, so
  457.          that it is still compatible with version 1.1...
  458.  
  459.       * Block Flipping
  460.  
  461.          Yes, I had a really nice routine, I had to use it for the blocks!
  462.          Two new instructions:
  463.  
  464.          HREV BLOCK number, flips horizontally
  465.          VREV BLOCK number, flips vertically
  466.  
  467.       * Bank Swapping
  468.  
  469.          A new and very needed instruction:
  470.  
  471.            Bank Swap number1,number2
  472.  
  473.          This instruction will swap the pointers of the two banks. Useful
  474.          if you want to turn an icon bank into a sprite bank. Example:
  475.  
  476.            Bank Swap 1,2
  477.  
  478.          or have more than one music bank at the same time, for example:
  479.  
  480.            Bank Swap 3,5
  481.  
  482.          etc...
  483.  
  484.       3 New Programs
  485.  
  486.          The AMOS1_2.AMOS updater has also  saved  a  few new programs onto
  487.          your disc:
  488.  
  489.          * CONFIG1_2.AMOS - the new configuration program. Note that the
  490.            configuration file in the AMOS_System folder is not the same as
  491.            the version 1_1 file.
  492.  
  493.          * MENU_EDITOR.AMOS - a new one, as AMOS had some annoying bugs in
  494.            fonts handling and ERRN functions.
  495.  
  496.          * LOCK.AMOS program! Yes, now you can lock your procedures, as
  497.            said in the manual. To proceed:
  498.  
  499.            1 Make a backup of your program, with OPENED procedures
  500.            2 Close all the procedures you wish to definitely lock
  501.            3 Load the LOCK.AMOS program, as an ACCESSORY
  502.            4 Run LOCK.AMOS using the RUN OTHER Menu option from the editor
  503.  
  504.          Your procedures are now locked, and you cannot open them back.
  505.  
  506.          NB: Do not try to load a program with locked procedures in
  507.              AMOS1_1 as it will crash the computer! Version 1_1 is designed
  508.              to disappear quickly!
  509.  
  510.          I am offering a bottle of (GOOD) French champagne to the first one
  511.          who will send me a program that unlocks another AMOS program, and
  512.          the LOCK.AMOS program unlocked. I wish you some happy hours trying
  513.          to find out how I did it! Hahaha!
  514.  
  515.  
  516.                                 AMOS Users Club
  517.                                -----------------
  518.  
  519.          Issue 1 of the AMOS Newsletter is now available. The club has
  520.      really taken off with over 700 members having joined - this is more
  521.      than the STOS club did in a year!
  522.          Adding a high score to Magic Forest, How I wrote Cartoon Capers,
  523.      Public Domain Update, A500 Blues and an article on Sprites, form the
  524.      main body of this first issue.
  525.          Join now - you won't regret it and you'll get all the latest AMOS
  526.      related news.
  527.  
  528.  
  529.                                 Soundtracker fix
  530.                                ------------------
  531.  
  532.          If you've experienced problems with the Soundtracker to AMOS
  533.      converter (found on the EXTRAS disc), then have a look at the listing
  534.      and ensure that line 61 is the same as below:
  535.  
  536.          OF_MUSIC=$43C
  537.  
  538.      Without this change the music tended to play out of sequence on one of
  539.      the channels.
  540.                                  AMOS's future
  541.                                 ---------------
  542.  
  543.          A look to the future! In the next few months, I will program:
  544.  
  545.          * A COMMS extension, to handle all RS232 and parallel
  546.            ports directly
  547.  
  548.          * An AREXX interface
  549.  
  550.          * The COMPILER!!! it is still time to send to Mandarin all your
  551.            ideas and suggestions for this important product. We will read
  552.            all the letters, as usual.
  553.  
  554.          I look forward to seeing what you have done in AMOS. Think about
  555.          the PD library, and do not keep your masterpieces for yourself
  556.          only! Send them to the club. I have already seen some amazing
  557.          stuff...
  558.  
  559.          That's all folks! I wish you as much fun programming in AMOS
  560.          as I had programming it!
  561.  
  562.  
  563.      PS - Thanks to all these persons for their nice letters and
  564.      intelligent remarks: J.M.Wright, Dr. Steve Hill, M. Radeley, T.W.
  565.      Davies, Fred Potter (Canada!), Mike Laskey, Frederic Calendini, C.
  566.      Savage, Michael Hawksworth, Richard A. Newbould, Robert Pirie, P.J.
  567.      Hasell, Eric Sagon, R.P. Couzens, Paul Loraine, C.A. Thompson, Andrew
  568.      Forrest, Rob Elsas, Matthew Clark, David Batty, Steve Bennett, David
  569.      Spacey, E. Spooner, Michael Ashton, H. Gibbens, Adrian Milliner, Gary
  570.      Field, C.J. Hoare, Peter Wade, Phillip Muldoon and all the ones I have
  571.      forgotten!
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.  
  587.  
  588.  
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598.  
  599.  
  600.  
  601.  
  602.  
  603.  
  604.